import axios from 'axios'

export function request(config) {
    const instance = axios.create({
        baseURL: '/api',
        timeout: 6000
    })
    instance.interceptors.request.use(config => {
        config.headers.Authorization = window.sessionStorage.getItem('token')
        return config
    })
    return instance(config)
}

export function request2(config) {
    const instance = axios.create({
        baseURL: '/zx',
        timeout: 6000
    })
    return instance(config)
}
export function request3(config) {
    const instance = axios.create({
        baseURL: '/sdf',
        timeout:6000
    })
    return instance(config)
}

